<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>flex-flow属性</title>
    <style>
        div {
            display: flex;
            width: 80%;
            height: 300px;
            background-color: pink;
            /* 设置主轴 */
            /* flex-direction: row; */
            /* 换行 */
            /* flex-wrap: wrap; */
            /* flex-flow属性,同时设置了flex-direction和flex-wrap属性 */
            flex-flow: row wrap;
        }

        span {
            width: 20%;
            height: 100px;
            background-color: skyblue;
            margin: 10px;
        }
    </style>
</head>

<body>
    <div>
        <span>1</span>
        <span>2</span>
        <span>3</span>
        <span>4</span>
        <span>5</span>
        <span>6</span>
    </div>
</body>

</html>